Skip to content

nvidia_dcgm: do not replace the DCGM that DGX OS already ships - #1394

Open
100-JM wants to merge 2 commits into
NVIDIA:masterfrom
100-JM:fix/nvidia-dcgm-do-not-downgrade-dgx
Open

nvidia_dcgm: do not replace the DCGM that DGX OS already ships#1394
100-JM wants to merge 2 commits into
NVIDIA:masterfrom
100-JM:fix/nvidia-dcgm-do-not-downgrade-dgx

Conversation

@100-JM

@100-JM 100-JM commented Sep 4, 2026

Copy link
Copy Markdown

Problem

roles/nvidia_dcgm/tasks/install-dgx.yml installs the unversioned datacenter-gpu-manager package on every DGX. In the CUDA apt repo that name resolves to DCGM 3.3.9. DGX OS 7.x already ships datacenter-gpu-manager-4-cuda13 (4.5.2). The two series conflict, so apt removes the 4.x packages and installs 3.3.9. The task reports ok, so nothing in the play fails.

The regression is only visible afterwards on the node:

$ dcgmi diag -r 1
Detected unsupported Cuda version        # 3.3.9 ships cuda10/11/12 plugins only; driver reports CUDA 13.0
$ dcgmi discovery -l | grep found
8 GPUs found.
0 NvSwitches found.                      # DGX B300 has two

The Ubuntu branch (install-ubuntu.yml) already uses {{ dcgm_pkg_name }}; only the DGX branch hardcodes the name. roles/nvidia-dgx/vars/ubuntu-24.04.yml lists datacenter-gpu-manager-4-cuda13 for DGX OS 7, so the two roles currently disagree.

Reproduced on DGX B300, DGX OS 7.5.0, driver 580.126.20, install_dcgm: true (default) via playbooks/slurm-cluster.yml.

Fix

Map each DGX OS release to the DCGM package it ships (dcgm_dgx_pkg_map, taken from roles/nvidia-dgx/vars; overridable via dcgm_dgx_pkg_name):

DGX OS Ubuntu package
4 18.04 datacenter-gpu-manager
5 20.04 datacenter-gpu-manager
6 22.04 datacenter-gpu-manager (current upstream behaviour kept — see note)
7 24.04 datacenter-gpu-manager-4-cuda13

On DGX the task now: fails clearly on an unmapped release; removes installed packages from the other DCGM series (datacenter-gpu-manager vs datacenter-gpu-manager-4-*); installs the mapped package when it is missing. A host already on the right package is untouched. Non-DGX branches are unchanged.

State → action on DGX OS 7:

installed remove install
-4-cuda13 + -4-core (healthy)
datacenter-gpu-manager 3.3.9 (this bug) datacenter-gpu-manager -4-cuda13
-4-core only (partial) -4-cuda13
nothing -4-cuda13

Note on DGX OS 6: roles/nvidia-dgx/vars/ubuntu-22.04.yml lists no DCGM package, so the map keeps what this role installs there today. If DGX OS 6 has moved to a -4-cuda12 package, that row should change; I could not verify it on hardware.

Verification

Restored the DGX OS version on the node (apt-get install datacenter-gpu-manager-4-cuda13=1:4.5.2-1 datacenter-gpu-manager-4-core=1:4.5.2-1):

$ dcgmi discovery -l | grep found
8 GPUs found (Active).
2 NvSwitches found.
$ dcgmi diag -r 1
DCGM Version 4.5.2, Driver 580.126.20, software: Pass on GPU0-7

Fabric Manager logs show the same two switches with 74 active links each. With the patched task, a re-run of slurm-cluster.yml leaves the 4.5.2 packages in place.

On DGX systems install-dgx.yml unconditionally installs the unversioned
datacenter-gpu-manager package, which the CUDA repo resolves to DCGM
3.3.9. DGX OS 7.x ships datacenter-gpu-manager-4-cuda13 (4.5.2). The two
series conflict, so apt removes the 4.x packages and installs 3.3.9. The
play reports ok and nothing stops; the regression only shows up later:
dcgmi diag fails with "Detected unsupported Cuda version" (3.3.9 has no
CUDA 13 plugin) and dcgmi discovery -l reports 0 NvSwitches on a DGX B300
that has two.

The Ubuntu branch already honours dcgm_pkg_name; only the DGX branch
hardcodes the name. roles/nvidia-dgx/vars/ubuntu-24.04.yml lists
datacenter-gpu-manager-4-cuda13 for DGX OS 7, so the two roles disagree.

Skip the install on DGX when any datacenter-gpu-manager package is
already present, and use dcgm_pkg_name otherwise.

Observed on DGX B300, DGX OS 7.5.0, driver 580.126.20.

Signed-off-by: 백지명 <wlaud9805@gmail.com>
@100-JM
100-JM marked this pull request as ready for review September 4, 2026 02:32

@dholt dholt left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please make the DGX task validate the specific acceptable DCGM package/version rather than treating any datacenter-gpu-manager* package as sufficient. Handle at least the existing legacy 3.x state, partial package sets, and the fully absent state so each converges to the correct DGX OS package; also ensure the absent-state package name is explicitly DGX-compatible instead of relying on the current unversioned default.


Automated triage review (agent-generated on the maintainer's behalf; a human maintainer decides merges).

Checking for any datacenter-gpu-manager* package was too loose: a host
already downgraded to 3.3.9 stayed there, a partial 4.x install was
accepted, and the absent case fell back to the unversioned metapackage
that caused the downgrade in the first place.

Map each DGX OS release to the package it ships (taken from
roles/nvidia-dgx/vars) as dcgm_dgx_pkg_map, overridable through
dcgm_dgx_pkg_name. On DGX: fail on an unmapped release, remove installed
packages from the other DCGM series, then install the mapped package
when it is missing. A host already on the right package is left alone,
so a second run reports ok.

Signed-off-by: 백지명 <wlaud9805@gmail.com>
@100-JM

100-JM commented Sep 6, 2026

Copy link
Copy Markdown
Author

Pushed a follow-up commit to address this.

The DGX branch now converges on the package the DGX OS release ships instead of accepting any datacenter-gpu-manager*. The mapping (dcgm_dgx_pkg_map, overridable via dcgm_dgx_pkg_name) is taken from what roles/nvidia-dgx/vars already installs per release: datacenter-gpu-manager for 18.04/20.04/22.04, datacenter-gpu-manager-4-cuda13 for 24.04. An unmapped release fails with an explicit message.

On DGX the task removes installed packages from the other DCGM series, then installs the mapped package when missing; a host already on the right package is untouched, so a second run is ok. Verified the state table (healthy / legacy 3.3.9 / partial -4-core / absent / mixed) and the override path locally against ansible-core 2.17.14; the PR description has the table.

Two points for you to confirm:

  • Version: the role validates the package series rather than pinning 1:4.5.2-1. DGX OS owns the exact DCGM version through its repo, and pinning here would fight its updates. If you want a pin, dcgm_dgx_pkg_name could take name=version.
  • DGX OS 6: roles/nvidia-dgx/vars/ubuntu-22.04.yml lists no DCGM package, so the map keeps the current upstream behaviour (datacenter-gpu-manager). I could not verify on DGX OS 6 hardware whether it has moved to a -4-cuda12 package; if it has, that row should change.

@100-JM

100-JM commented Sep 6, 2026

Copy link
Copy Markdown
Author

@dholt The requested changes are pushed (see the comment above for details) — ready for another look when you have a moment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants